package cn.kgc.service;

import cn.kgc.entity.Menus;
import cn.kgc.entity.RouterVo;
import com.baomidou.mybatisplus.extension.service.IService;
import org.springframework.security.core.authority.SimpleGrantedAuthority;

import java.util.List;

/**
 * @author wangyue
 * @version 1.0
 */
public interface MenusService extends IService<Menus> {
    /**
     * 根据角色id查询菜单信息
     *
     * @param roleId 角色id
     * @return 角色拥有的菜单信息
     */
    List<Menus> findMenusByRoleId(int roleId);

    List<SimpleGrantedAuthority> getAuthorityByRoleId(int roleId);

    /**
     * 获得用户对应按钮的权限标识符
     *
     * @return
     */
    List<String> getMenuPerms();

    List<RouterVo> getRouterVoList();
}
